﻿using System;
using System.Data;
using System.Collections;
using CE.Database;

/// <summary>
/// Summary description for EtiqaProposalFileDB
/// </summary>
/// 
namespace CE.PersonalAccident
{
    public class EtiqaProposalFileDB
    {
        public EtiqaProposalFileDB()
        {
            //
            // TODO: Add constructor logic here
            //
        }

        public Int64 Insert(EtiqaProposalFile etiqaproposalfile)
        {
            MyDatabase _db = new MyDatabase();
            Int64 _result = -1;
            string _spName = "[sprocPAProposalFileInsertUpdateSingleItem]";

            SortedList _sPara = new SortedList();

            #region Parameter
            _sPara.Add("@PAProposalFileId", etiqaproposalfile.PAProposalFileId);
            _sPara.Add("@ProviderCompanyId", etiqaproposalfile.ProviderCompanyId);
            _sPara.Add("@FileName", etiqaproposalfile.FileName);
            _sPara.Add("@Issued", etiqaproposalfile.Issued);
            _sPara.Add("@Status", etiqaproposalfile.Status);
            _sPara.Add("@PAIdList", etiqaproposalfile.PAIdList);
            #endregion

            _result = _db.ExecuteSP(_spName, _sPara);

            return _result;
        }

    }
}